import request from '@/utils/request';

// 运费模板
export async function addTemple(params = {}) {
  return request('/Amaidan-Order-Web/ord/logisticsTemplate/addLogisticsTemplate', {
    method: 'POST',
    data: params,
  });
}

export async function getTemplateById(params = {}) {
  return request('/Amaidan-Order-Web/ord/logisticsTemplate/getTemplateById', {
    method: 'POST',
    data: params,
  });
}

export async function updateTmp(params = {}) {
  return request('/Amaidan-Order-Web/ord/logisticsTemplate/updateLogisticsTemplate', {
    method: 'POST',
    data: params,
  });
}


export async function fetchTemple(params = {}) {
  return request('/Amaidan-Order-Web/ord/logisticsTemplate/queryLogisticsTemplate', {
    method: 'POST',
    data: params,
  });
}

export async function fetchComponyList(params = {}) {
  return request('/Amaidan-Order-Web/ord/LogisticsCompany/logisticsCompanyList', {
    method: 'POST',
    data: params,
  });
}

export async function addCompony(params = {}) {
  return request('/Amaidan-Order-Web/ord/LogisticsCompany/addLogisticsCompany', {
    method: 'POST',
    data: params,
  });
}

export async function delCompony(params = {}) {
  return request('/Amaidan-Order-Web/ord/LogisticsCompany/delete', {
    method: 'POST',
    data: params,
  });
}
// 同城配送
export async function fetchDeliveryList(params = {}) {
  return request('/Amaidan-Merchants-Web/merchant/busCityDeliveryType/selectCityDeliveryType', {
    method: 'POST',
    data: params,
  });
}

export async function addDelivery(params = {}) {
  return request('/Amaidan-Merchants-Web/merchant/busCityDeliveryType/insertCityDeliveryType', {
    method: 'POST',
    data: params,
  });
}

